<?php
/**
 * Created by PhpStorm.
 * User: USER
 * Date: 2017/10/12
 * Time: 17:26
 */

namespace app\user\controller;
use app\user\controller\Base;
use think\Session;

class Info extends Base
{

    //    渲染用户信息展示页面
    public function usinfo()
    {

//       获取Session
            $uname=session::get('name','think');
            $upwd=session::get('pwd','think');
//        执行查询用户信息
        $user=M();
        $select=$user->query("select * from ole_users where name='$uname' and password='$upwd'");

        $this->assign('index/home',$select);              // 传递变量
        $this ->display('usinfo.html');
    }
}